- form = local_assigns.fetch(:form)

= render 'projects/settings/merge_requests/merge_request_merge_method_settings', project: @project, form: form

= render 'projects/settings/merge_requests/merge_request_merge_options_settings', project: @project, form: form

= render 'projects/settings/merge_requests/merge_request_squash_options_settings', form: form

= render 'projects/settings/merge_requests/merge_request_merge_checks_settings', project: @project, form: form

- if @project.licensed_feature_available?(:external_status_checks)
  = render_if_exists 'projects/settings/merge_requests/merge_request_status_checks_settings'

= render 'projects/settings/merge_requests/merge_request_merge_suggestions_settings', project: @project, form: form

= render 'projects/settings/merge_requests/merge_request_merge_commit_template', project: @project, form: form

= render 'projects/settings/merge_requests/merge_request_squash_commit_template', project: @project, form: form

- if @project.forked?
  = render 'projects/settings/merge_requests/merge_request_target_project_settings', project: @project, form: form

- if @project.feature_available?(:issuable_default_templates)
  .form-group
    %b= _('Default description template for merge requests')
    %p.text-secondary
      = s_('ProjectSettings|Used for every new merge request.')
      - create_a_merge_request_template_help_link_url = help_page_path('user/project/description_templates', anchor: 'create-a-merge-request-template')
      - create_a_merge_request_templates_help_link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: create_a_merge_request_template_help_link_url }
      = s_('ProjectSettings|%{link_start}What are description templates?%{link_end}').html_safe % { link_start: create_a_merge_request_templates_help_link_start, link_end: '</a>'.html_safe }

    = form.text_area :merge_requests_template, class: "form-control", rows: 3, data: { qa_selector: 'default_merge_request_template_field' }

    .text-secondary
      - link_start = '<a href="%{url}" target="_blank" rel="noopener noreferrer">'.html_safe % { url: help_page_path('user/markdown') }
      = _('Description parsed with %{link_start}GitLab Flavored Markdown%{link_end}').html_safe % { link_start: link_start, link_end: '</a>'.html_safe }
